package com.example.sys.controller;

import com.example.common.vo.Result;
import com.example.sys.entity.Scheduling;
import com.example.sys.entity.User;
import com.example.sys.entity.UserRole;
import com.example.sys.service.IUserRoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author wuage
 * @since 2023-12-20
 */
@RestController
@RequestMapping("/userRole")
public class UserRoleController {
    @Autowired
    private IUserRoleService userRoleService;

    @GetMapping("/allName")
    public Result infoName(){
        List<User> userList = userRoleService.listName();

        return Result.success(userList);
    }
}
